<#include "../_inc/_layout.html"/> 
<#include "_option_script.html"/> 
<@layout active_id=p child_active_id=c>
<section class="content-header">
	<h1>消息设置</h1>
</section>

<!-- Main content -->
<section class="content">
	<p class="content-msg">
		JPress让。。。 
	</p>
	
	<form action="${CPATH}/admin/option/save" method="POST" id="form">
	
		<input type="hidden" name="ucode" value="${ucode}">
		<input type="hidden" name="autosave" value="email_host,email_username,email_password,email_usessl,sms_host,sms_app_secret,sms_app_key">

		<div class="row">
			<div class="col-xs-12">
			<h4 class="jp-set-title">邮件</h4>
			<ul class="list-unstyled">
				<li class="jp-set-pad">
					<div class="col-sm-3 col-jpress">
						<div class="  jp-set-info ">
							 SMTP服务器地址
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<input class="form-control input-md" type="text" name="email_host" value="${option('email_host')!}" >
							请填写邮箱的SMTP服务器。例如：smtp.qq.com (QQ邮箱)，smtp.163.com (网易邮箱)。
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
				<li class="jp-set-pad">
					<div class="col-sm-3 ">
						<div class="  jp-set-info ">
							用户名
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<input class="form-control input-md" type="text" name="email_username" value="${option('email_username')!}" >
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
				<li class="jp-set-pad">
					<div class="col-sm-3 ">
						<div class="  jp-set-info ">
							 账号密码
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<input class="form-control input-md" type="text" name="email_password" value="${option('email_password')!}" >
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
				<li class="jp-set-pad">
					<div class="col-sm-3 ">
						<div class="  jp-set-info ">
							 SSL
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<label><input class=" " type="checkbox"  name="email_usessl" value="true" ${checked('email_usessl')}  >  <span class="jp-set-info"> 使用SSL</span></label>
							<br />QQ邮箱，gmail邮箱，163邮箱等请开启。
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
				
			</ul>
			</div>
			<!-- /.box -->
		</div>
		
		<div class="row">
			<div class="col-xs-12">
			<h4 class="jp-set-title">短信</h4>
			<ul class="list-unstyled">
				<li class="jp-set-pad">
					<div class="col-sm-3 col-jpress">
						<div class="  jp-set-info ">
							 短信服务器
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<select name="sms_app_provider" class="form-control input-md">
								<option value="sms_provider_alidayu" >阿里大鱼</option>
							</select>
							暂时只支持阿里大鱼，后续会增加更多的短信服务器，阿里大鱼官网：<a href="http://www.alidayu.com" target="_blank">http://www.alidayu.com</a>。
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
				<li class="jp-set-pad">
					<div class="col-sm-3 ">
						<div class="  jp-set-info ">
							App Key
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<input class="form-control input-md" type="text" name="sms_app_key" value="${option('sms_app_key')!}" >
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
				<li class="jp-set-pad">
					<div class="col-sm-3 ">
						<div class="  jp-set-info ">
							 App Secret
						</div>
					</div>
					<div class="col-sm-9  jp-set-title-line">
						<div class="col-sm-6 jp-table-distance-top ">
							<input class="form-control input-md" type="text" name="sms_app_secret" value="${option('sms_app_secret')!}" >
						</div>
					</div>
					<div class="clr"></div>
				</li>
				
			</ul>
			</div>
			<!-- /.box -->
		</div>
		
		<div class="row">
		<div class="col-xs-12">
			<button type="button" onclick="doSubmit()" class="btn btn-primary">保存更改</button>
		</div>
		</div>
	<!-- /.row -->
	</form>
</section>
<!-- /.content -->

</@layout>
